package joda;

import org.joda.time.DateTime;
import org.joda.time.LocalDate;
import org.joda.time.LocalDateTime;
import org.joda.time.LocalTime;

/**
 * Created by IntelliJ IDEA.
 * User: liuliwei
 * Date: 2017-06-07
 * Time: 上午9:59
 * Description: ${description}
 */
public class DateTimeTest {
    public static void main(String[] args) {
        System.out.println(getLocalDateNow());

        System.out.println(LocalDateTime.now());
        System.out.println(LocalTime.now());
        System.out.println(DateTime.now());
    }

    private static LocalDate getLocalDateNow() {
        LocalDate now = LocalDate.now();
        LocalDate now1=LocalDate.parse("2016-06-06");
        System.out.println("nowToString"+now.toString("YYYY:M:mm:MM:yyyy:d:ddd:D:DDD"));
        System.out.println("now1:"+now1);
        return now;
    }
}
